<!--{Atemplate tpl/header}-->
<!--{eval echo $this->Ahtml_js_aurl();}-->
<script type="text/javascript" charset="utf-8">

auto_stat_ip = function(){
	var time = jQuery("#stat_time").val();
	if(time<1){
		time = 1;
	}
	jQuery(".stat_type").html(time+'秒后自动刷新...');
	setTimeout("stat_ip(1)",time*1000);
}

stat_ip = function(str){
	var save = '';
	jQuery.ajax({type: "POST",url: Aurl.Amodr+"-stat_ip_ajax",data: save,
		beforeSend: function(){jQuery(".stat_status").html('开始请求');},
		ajaxSend: function(){jQuery(".stat_status").html('发送请求');},
		success: function(data){
			jQuery(".stat_status").html('请求完成');
			jQuery(".stat_ip_htm").html(data);
		}
	})
	if(str==1){
		auto_stat_ip();
	}
}
jQuery(document).ready(function(){
	stat_ip(1);
});


</script>
<div class="stat_ip">
<input type="button" name="" value="刷新" onclick="stat_ip()"/>  
刷新时间:<input type="range" value="3" id="stat_time" min="1" max="10" step="1"/>
<input type="button" name="" value="自动刷新" onclick="auto_stat_ip()"/>
<div id="status">
	<span class="stat_type"></span>
	<span class="stat_status"></span>
</div>
<div class="stat_ip_htm"></div>
</div>
<!--{Atemplate tpl/footer}-->